#ifndef __KLIBTYPES_H_
#define __KLIBTYPES_H_



typedef unsigned char uchar;
typedef unsigned char byte;
typedef char CharA;
typedef wchar_t CharW;
typedef std::basic_string <char> StringA;
typedef std::basic_string <wchar_t> StringW;
typedef std::basic_stringstream <char> StringStreamA;
typedef std::basic_stringstream <wchar_t> StringStreamW;
typedef std::basic_fstream <char> FileStreamA;
typedef std::basic_fstream <wchar_t> FileStreamW;
typedef std::basic_fstream <byte> FileStreamBinary;
typedef std::basic_ostringstream<char> OStringStreamA;
typedef std::basic_ostringstream<wchar_t> OStringStreamW;

//Define String etc according to what character set is currently being used
#ifdef _UNICODE
	typedef StringW String;
	typedef StringStreamW StringStream ;
	typedef FileStreamW FileStream ;
	typedef CharW Char;
	typedef OStringStreamW OStringStream;
#else
	typedef StringA String;
	typedef StringStreamA StringStream ;
	typedef FileStreamA FileStream ;
	typedef CharA Char;
	typedef OStringStreamA OStringStream;
#endif



typedef unsigned short u16;
typedef signed short i16;
typedef unsigned int u32;
typedef signed int i32;
typedef unsigned long ulong;
typedef unsigned __int64 u64;
typedef signed __int64 i64;
typedef unsigned __int64 ResourceID;
typedef unsigned __int64 EntityID;
typedef unsigned __int64 NodeID;
typedef unsigned __int64 ObjectID;
typedef float REAL;
typedef std::map <String, String> KeyValuePair;
typedef std::vector <String>StringArray;




#endif